package me.flyray.biz.thymeleaf.modules.goods.rest;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import com.github.wxiaoqi.security.common.msg.TableResultResponse;
import com.github.wxiaoqi.security.common.qr.request.QrQueryOrderParam;

import me.flyray.biz.thymeleaf.api.BaseController;
import me.flyray.biz.thymeleaf.modules.goods.biz.QrGoodsOrderBiz;
import me.flyray.biz.thymeleaf.modules.goods.entity.QrGoodsOrder;


/**
 * 商品订单
 * @author Administrator
 *
 */
@Controller
@RequestMapping("qrGoodsOrders")
public class QrGoodsOrderController extends BaseController {
	
	private static final Logger logger = LoggerFactory.getLogger(QrGoodsOrderController.class);

	@Autowired
	private QrGoodsOrderBiz orderBiz;
	
	/**
	 * 查询商品列表
	 * @param param
	 * @return
	 */
	@ResponseBody
	@RequestMapping(value="/list", method=RequestMethod.POST)
	public TableResultResponse<QrGoodsOrder> query(@RequestBody QrQueryOrderParam param) {
		logger.info("查询商品订单列表。。。{}"+param);
		return orderBiz.queryList(param);
	}
}